package fnsvr

import "encoding/base64"

//base64编码
func Base64Encode(input []byte) string {
	return base64.StdEncoding.EncodeToString(input)
}

//base64解码
func Base64Decode(encoded string) ([]byte, error) {
	decoded, err := base64.StdEncoding.DecodeString(encoded)
	if err != nil {
		return nil, err
	}
	return decoded, nil
}
